Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ckeditor/ckeditor5-engine

Package Overview
Dependencies
Maintainers
1
Versions
707
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ckeditor/ckeditor5-engine

CKEditor 5 editing engine.

  • 1.0.0-beta.4
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
578K
decreased by-29.45%
Maintainers
1
Weekly downloads
 
Created

What is @ckeditor/ckeditor5-engine?

@ckeditor/ckeditor5-engine is a core package of CKEditor 5, a modern JavaScript rich text editor. This package provides the engine that powers the editor, including the data model, editing view, and rendering process. It is highly modular and extensible, allowing developers to create custom editing experiences.

What are @ckeditor/ckeditor5-engine's main functionalities?

Creating a Document

This feature allows you to create a new document instance, which is the core of the editing engine. The document holds the data model and manages the editing operations.

const { Document } = require('@ckeditor/ckeditor5-engine');
const doc = new Document();
console.log(doc);

Adding a Root Element

This feature allows you to add a root element to the document. The root element is the top-level container for the document's content.

const { Document } = require('@ckeditor/ckeditor5-engine');
const doc = new Document();
const root = doc.createRoot();
console.log(root);

Inserting Text

This feature allows you to insert text into the document. The Writer class is used to perform editing operations on the document.

const { Document, Writer } = require('@ckeditor/ckeditor5-engine');
const doc = new Document();
const root = doc.createRoot();
const writer = new Writer();
writer.insertText('Hello, world!', root);
console.log(root);

Listening to Changes

This feature allows you to listen to changes in the document. The document emits events whenever its content is modified, enabling you to react to these changes.

const { Document } = require('@ckeditor/ckeditor5-engine');
const doc = new Document();
doc.on('change', (event, batch) => {
  console.log('Document changed:', batch);
});

Other packages similar to @ckeditor/ckeditor5-engine

Keywords

FAQs

Package last updated on 20 Apr 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc